package com.nuoniu.sibanyun.service.production;

import com.baomidou.mybatisplus.extension.service.IService;
import com.nuoniu.sibanyun.entity.bo.UnExecutedBo;
import com.nuoniu.sibanyun.entity.production.VProductionWorkDetail;
import com.nuoniu.sibanyun.entity.production.VProductionWorkInventoryDetail;
import com.nuoniu.sibanyun.entity.production.VProductionWorkMain;

import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author 白强
 * @since 2021-03-20
 */
public interface IVProductionWorkInventoryDetailService extends IService<VProductionWorkInventoryDetail> {

    /**
     * 批量保存 材料明细
     * @param productionWorkMain
     * @param detailIds
     */
    void batchSave(VProductionWorkMain productionWorkMain,List<Long> detailIds);


    /**
     * 获取派工单 物料明细
     * @param dispatchId 派工单ID
     * @return
     */
    List<VProductionWorkInventoryDetail> listByProductionDispatchId(Long dispatchId);

    /**
     * 通过 加工单ID 查询物料明细
     * @param productionWorkMainId
     * @return
     */
    List<VProductionWorkInventoryDetail> listByProductionWorkId(Long productionWorkMainId);

    List<UnExecutedBo> getUnExecuteQuantity(String inventoryIds,String warehouseIds);


    /**
     * 根据 加工单ID 删除 材料明细
     * @param mainId
     */
    void deleteFromMainId(Long mainId);





}
